package com.sanjiahantang.youjiaclient.module.evaluate.beans;

import com.google.gson.Gson;
import com.sanjiahantang.youjiaclient.base.BaseBean;
import com.sanjiahantang.youjiaclient.module.goods.beans.GoodsBean;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
 * Created by zy on 2017/9/6.
 */

public class EvaGoodsBean extends BaseBean {


    private String data;

    public Data getData() {
        return new Gson().fromJson(data,Data.class);
    }

    public void setData(String data) {
        this.data = data;
    }

    public static class Data extends ListBean{
        private List<Item> list;

        public List<Item> getList() {
            return list;
        }

        public void setList(List<Item> list) {
            this.list = list;
        }
    }

    public static class Item implements Serializable{
        private String skuFaId;
        private String isReplyName;
        private String goodsPropertyName;
        private String number;
        private String phone;
        private int isReplyId;
        private String createTime;
        private int mgiId;
        private String orderCode;
        private String place;
        private int maiId;
        private String goodsName;
        private String replyPlace;
        private String appraiseUrl;
        private String mallUrl;
        private float basePrice;
        private List<GoodsBean.Image> imgUrlList;

        public List<GoodsBean.Image> getImgUrlList() {
            return imgUrlList;
        }

        public void setImgUrlList(List<GoodsBean.Image> imgUrlList) {
            this.imgUrlList = imgUrlList;
        }

        public List<Image> getImages(){
            List<Image> imgList = new ArrayList<>();
            if (appraiseUrl != null){
                String[] arr = appraiseUrl.split(",");
                for (int i = 0;i<arr.length;i++){
                    Image img = new Image();
                    img.setUrl(arr[i]);
                    imgList.add(img);
                }
            }
            return imgList;
        }

        public String getAppraiseUrl() {
            return appraiseUrl;
        }

        public void setAppraiseUrl(String appraiseUrl) {
            this.appraiseUrl = appraiseUrl;
        }

        public String getMallUrl() {
            return mallUrl;
        }

        public void setMallUrl(String mallUrl) {
            this.mallUrl = mallUrl;
        }

        public float getBasePrice() {
            return basePrice;
        }

        public void setBasePrice(float basePrice) {
            this.basePrice = basePrice;
        }

        public String getReplyPlace() {
            return replyPlace;
        }

        public void setReplyPlace(String replyPlace) {
            this.replyPlace = replyPlace;
        }

        public String getSkuFaId() {
            return skuFaId;
        }

        public void setSkuFaId(String skuFaId) {
            this.skuFaId = skuFaId;
        }

        public String getIsReplyName() {
            return isReplyName;
        }

        public void setIsReplyName(String isReplyName) {
            this.isReplyName = isReplyName;
        }

        public String getGoodsPropertyName() {
            return goodsPropertyName;
        }

        public void setGoodsPropertyName(String goodsPropertyName) {
            this.goodsPropertyName = goodsPropertyName;
        }

        public String getNumber() {
            return number;
        }

        public void setNumber(String number) {
            this.number = number;
        }

        public String getPhone() {
            return phone;
        }

        public void setPhone(String phone) {
            this.phone = phone;
        }

        public int getIsReplyId() {
            return isReplyId;
        }

        public void setIsReplyId(int isReplyId) {
            this.isReplyId = isReplyId;
        }

        public String getCreateTime() {
            return createTime;
        }

        public void setCreateTime(String createTime) {
            this.createTime = createTime;
        }

        public int getMgiId() {
            return mgiId;
        }

        public void setMgiId(int mgiId) {
            this.mgiId = mgiId;
        }

        public String getOrderCode() {
            return orderCode;
        }

        public void setOrderCode(String orderCode) {
            this.orderCode = orderCode;
        }

        public String getPlace() {
            return place;
        }

        public void setPlace(String place) {
            this.place = place;
        }

        public int getMaiId() {
            return maiId;
        }

        public void setMaiId(int maiId) {
            this.maiId = maiId;
        }

        public String getGoodsName() {
            return goodsName;
        }

        public void setGoodsName(String goodsName) {
            this.goodsName = goodsName;
        }

    }

    public static class Tag{
        private String name;
        private String id;

        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public String getId() {
            return id;
        }

        public void setId(String id) {
            this.id = id;
        }
    }



}
